import { IMessageBase } from "../../Framework/MQ/IMessageBase";
import { MessageManager } from "../../Framework/MQ/MessageManager";
import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
import { DictLotteryItemInfoHelper } from "./DictLotteryItemInfoHelper";
import { SeqLotteryItemInfoHelper } from "./SeqLotteryItemInfoHelper";
type int = number;
//class SDramaLotteryInfo
    
    export  class SDramaLotteryInfo extends IMessageBase
    {
        constructor(arg1: Boolean=false)
        {
            
            super();if (arg1) 
            {
                MessageManager.instance().regist(this);
            }
            return;
        }

        public /* override */ getType(): int
        {
            return this._type;
        }

        public /* override */ clone(): IMessageBase
        {
            return new SDramaLotteryInfo();
        }

        public /* override */ __write(arg1: SerializeStream): void
        {
            arg1.writeInt(this.leftFreeTimes);
            arg1.writeInt(this.leftBuyTimes);
            DictLotteryItemInfoHelper.write(arg1, this.lotteryItems);
            SeqLotteryItemInfoHelper.write(arg1, this.myHistory);
            return;
        }

        public /* override */ __read(arg1: SerializeStream): void
        {
            this.leftFreeTimes = arg1.readInt();
            this.leftBuyTimes = arg1.readInt();
            this.lotteryItems = DictLotteryItemInfoHelper.read(arg1);
            this.myHistory = SeqLotteryItemInfoHelper.read(arg1);
            return;
        }

        public /* const */_type: int=12454;

        public /* var */leftFreeTimes: int;

        public /* var */leftBuyTimes: int;

        public /* var */lotteryItems: Map<any, any> /* flash.utils.Dictionary */;

        public /* var */myHistory: Array<any>;

        public static /* var */_regist: SDramaLotteryInfo;
    }

            SDramaLotteryInfo._regist = new SDramaLotteryInfo(true);
        